<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:ui="http://java.sun.com/jsf/facelets">
    <h:head>
        <title>Facelet Title</title>
    </h:head>
    <h:body>
        <ui:composition>
            <h:form>
                <h:outputLink value="../../LogUtServlet" rendered="#{not user.checkLogin}" ><h:outputText value="#{locale.menuLogout}" /></h:outputLink>
                <h:outputLink value="/SystemeringProsjekt/faces/protected/myCourses.xhtml" rendered="#{user.checkLogin}">#{locale.menuLogin}</h:outputLink><h:outputText value=" | " rendered="#{not user.checkLogin}" />
                <h:commandLink value="#{locale.menuUsers}" action="#{userList.navToUserList}" rendered="#{user.isSysadmin}" /><h:outputText value=" | " rendered="#{user.isSysadmin}" />
                <h:commandLink value="#{locale.menuStudprog}" action="#{studyprogramList.navToStudyprogList}" rendered="#{user.isSysadmin}" /><h:outputText value=" | " rendered="#{user.isSysadmin}" />
                <h:commandLink value="#{locale.menuDep}" action="#{departmentList.navToDepartmentList}" rendered="#{user.isSysadmin}" /><h:outputText value=" | " rendered="#{user.isSysadmin}" />
                <h:commandLink value="#{locale.menuInst}" action="#{instituteList.navToInstituteList}" rendered="#{user.isSysadmin}" /><h:outputText value=" | " rendered="#{user.isSysadmin}" />
                <h:commandLink value="#{locale.menuMyPage}" action="#{myCourses.navToMyCourses}" rendered="#{not user.checkLogin}" /><h:outputText value=" | " rendered="#{not user.checkLogin}" />
                <h:commandLink value="#{locale.menuAllCourses}" action="#{allCourses.navToAllCourses}" rendered="#{not user.checkLogin}" /><h:outputText value=" | " rendered="#{not user.checkLogin}" />
                <h:commandLink value="#{locale.menuChangePassword}" action="changePassword" rendered="#{not user.checkLogin}" /><h:outputText value=" | " rendered="#{not user.checkLogin}" />
                <h:commandLink value="old_#{locale.menuLogout}" action="#{user.logout}" rendered="#{not user.checkLogin}" />
            </h:form>
            <h:form>
                <h:inputText value="#{courseSearch.searchString}" rendered="#{not user.checkLogin}"/>
                <h:commandButton value="#{locale.menuSearch}" type="submit" action="#{courseSearch.Search}" rendered="#{not user.checkLogin}" />
            </h:form>
        </ui:composition>
    </h:body>
</html>
